Ext.define('BM.view.trade.CustomerBook', {
    extend: 'Ext.window.Window',
    alias : 'widget.customerbook',
    title : '宾客预订',
    layout: 'fit',
    height: 320,
    width : 600,
    autoShow: true,
    initComponent: function() {
        this.items = [
        {
        	xtype:'form',
        	frame:false,
        	layout: 'border',
        	fieldDefaults: {
	       	    labelWidth: 75,
	           	labelAlign: 'right'
     		},
        	items:[
        	{
	        	region:'north',
	        	border:false,
	        	items:{
		        	xtype:'panel',
		        	border:false,
		        	height:10
	        	}
        	},{
        	region:'west',
        	width:250,
        	border:false,
        	height:190,
        	items:[{
                  xtype: 'textfield',
                  name : 'goodsItemtNum',
                  fieldLabel: '宾客姓名',
                  allowBlank: false
              },
              {
                  xtype: 'textfield',
                  name : 'goodsItemName',
                  fieldLabel: '联系电话',
                  allowBlank: false 
              },
              {
                  xtype: 'textfield',
                  name : 'goodsItemName_S',
                  fieldLabel: '预订规格'
              },
              {
                  xtype: 'textfield',
                  name : 'unit',
                  fieldLabel: '房间编号',
                  allowBlank: false
              },
              {
                  xtype: 'textfield',
                  name : 'cost',
                  fieldLabel: '抵达时间',
                  allowBlank: false 
              },
              {
                  xtype: 'textfield',
                  name : 'cost',
                  fieldLabel: '保留时间',
                  allowBlank: false 
              }]
        	},{
        	 region: 'center',
        	 margins: '2 0 2 0',
        	 height:190,
        	 width:340,
        	 border:false,
        	 items:[{
	        	xtype:'fieldset',
	            title: '已预订此房间的宾客',
	            collapsible: true,
	            defaults: {
	                anchor: '100%'
	            }}
            ]
        	},{
        	 region: 'south',
        	 margins: '2 0 2 0',
        	 height:80,
        	 border:false,
        	 items:[
              {
                  xtype: 'textarea',
                  name : 'memo',
                  width:500,
                  height:50,
                  fieldLabel: '备注',
                  allowBlank: false 
              },{
              	 xtype:'checkbox',
              	 boxLabel: '到达保留时间，是否自动取消预订',
                 hideEmptyLabel: false}]
        	}
        	]
        
        }
        ];

        this.buttons = [
            {
                text: '确定',
                action: 'save'
            },
            {
                text: '取消',
                scope: this,
                handler: this.close
            }
        ];

        this.callParent(arguments);
    }
});